import { Button } from "antd";
import { memo } from "react";
import { useNavigationWithState } from "@/hooks/useNavigationWithState";
const OriginalTech = memo(() => {
  const navigate = useNavigationWithState();
  return (
    <div className="p-4">
      <Button onClick={() => { navigate(`/article/1`) }}>测试自定义hook - useNavigationWithState</Button>
      <p className="my-6 text-sm text-gray-500">
        携带当前路由状态跳转，可以实现返回上一级
      </p>
      <Button onClick={() => { navigate(`/404`) }}>404页面展示</Button>
    </div>
  );
});

OriginalTech.displayName = "OriginalTech";
export default OriginalTech;